#include <iostream>



class Drink
{
public:
    virtual void Boil() = 0;  //烧水
    virtual void Brew() = 0;  //冲泡
    virtual void Put() = 0;   //放入辅料
    void MakeDrink()
    {
        Boil();
        Brew();
        Put();
    }
};

class MilkTea
{
public:
    void Boil()
    {
        std::cout<<"烧开水\n";
    }
    virtual void Brew()
    {
        std::cout<<"倒入奶茶粉\n";
    }
    virtual void Put()
    {
        std::cout<<"放入椰果\n";
    }
};

class Coffee:public Drink
{
public:
    void Boil()
    {
        std::cout<<"烧开水\n";
    }
    virtual void Brew()
    {
        std::cout<<"倒入咖啡粉搅拌\n";
    }
    virtual void Put()
    {
        std::cout<<"放入冰块\n";
    }
};

int main()
{
    Drink *d = new Coffee;
    d->MakeDrink();
    return 0;
}